package xukj.proxy;

/**
 * @ClassName Proxy
 * @Description
 * @Author xukj
 * @Date 2019/1/10 17:39
  @Version
 */
public class Proxy {
    public static <T> T create(Class<T> clazz) {

        T proxyWork = (T) java.lang.reflect.Proxy.newProxyInstance(clazz.getClassLoader(),
                new Class[]{clazz}, new MyHandler());
        return proxyWork;
    }
}
